<template>
	<div>
		<el-row>
			<el-col :span="24">
				<span class="myspan2">
					<img class="tutou" src="../../assets/tutouguai.png" />
					尊敬的{{username}}用户,欢迎您进入CRM后台管理系统!!!
				</span>
			</el-col>
		</el-row>
		<el-row :gutter="8">
			<el-col :span="15">
				<el-carousel :interval="intervalTime" arrow="always" height="500px" style="margin-top: 100px;">
					<el-carousel-item v-for="item in 4" :key="item">
					</el-carousel-item>
				</el-carousel>
			</el-col>
			<el-col :span="8">
				<div>
					<h1 style="margin-top: 100px;">
						舔狗日记
					</h1>
					<div>

						<el-divider>

						</el-divider>
						<span style="font-size: 20px;">
							{{content}}
						</span>
					</div>
				</div>
			</el-col>
		</el-row>
	</div>
</template>

<script>
	export default {
		data() {
			return {
				username: "",
				content: '',
				timer: "",
				timer2: "",
				intervalTime: 0,
			}
		},
		methods: {
			
			// valChange() {
			//  // 在这里调用后端接口，返回content内容
			// 	this.$axios.get("/welcome").then(resp => {
			// 		this.content = resp.data;
			// 	})
			// },
			// changeInterval() {
			// 	// console.log(111111111);
			// 	this.$axios.get("/welcome/slideshow").then(resp => {
			// 		this.intervalTime = resp.data;
			// 	})
			// },
			// over() {
			// 	clearInterval(this.timer);
			// 	clearInterval(this.timer2);
			// }
		},
		mounted() {
			this.username = localStorage.getItem("userName");
			// this.start();
		},
		beforeDestroy() {
			// clearTimeout(this.timer);
			// clearTimeout(this.timer2);
		}
	}
</script>

<style>
	.myspan2 {
		font-size: 50px;
		color: #00aa00;

	}

	.myPro {
		height: 840px;
		width: 1622px;
	}

	.tutou {
		height: 50px;
		width: 40px;
	}

	.el-carousel__item:nth-child(4n) {
		background-image: url("../../assets/Professional.jpg");
		background-repeat: no-repeat;
		background-size: 100%;
	}

	.el-carousel__item:nth-child(4n+1) {
		background-image: url("../../assets/one.jpg");
		background-repeat: no-repeat;
		background-size: 100%;
	}

	.el-carousel__item:nth-child(4n+2) {
		background-image: url("../../assets/two.jpg");
		background-repeat: no-repeat;
		background-size: 100%;
	}

	.el-carousel__item:nth-child(4n+3) {
		background-image: url("../../assets/three.jpg");
		background-repeat: no-repeat;
		background-size: 100%;
	}
</style>
